package com.huangpeng.sdst.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.huangpeng.sdst.entity.Order;
import com.huangpeng.sdst.entity.OrderQueryBo;
import com.huangpeng.sdst.entity.SearchBo;

import java.util.List;

/**
 * @Author huangpeng
 * @Title 订单服务接口
 * @Package
 * @Date 2020/8/25 16:01
 * @Description
 * @Version 1.0
 */
public interface IOrderService extends IService<Order> {
    /**
     * 保存订单
     * @param order
     * @return
     */
    public boolean saveOrder(Order order);

    /**
     *  查询所有订单
     * @return
     */
    public IPage<Order> getOrderPageList(SearchBo<OrderQueryBo> queryBo);

    /**
     * 删除订单
     * @param orderId
     * @return
     */
    public Integer deleteOrder(Long orderId);

    /**
     * 更新订单
     * @param order
     * @return
     */
    public boolean updateOrder(Order order);

    /**
     * 订单集合查询
     * @param queryBo
     * @return
     */
    public List<Order> getOrderList(SearchBo<OrderQueryBo> queryBo);

    /**
     * 订单查询根据id
     * @param orderId
     * @return
     */
    public Order getOrderById(Long orderId);
}
